<div class="box-body" style="display: block;">
    <form method="POST" action="/xqc/inventory/transfer-p-upload" class="form-horizontal" accept-charset="UTF-8" enctype="multipart/form-data">
        <div class="box-body fields-group">
            <div class="form-group">
                <label class="col-sm-3 control-label"></label>
                <div class="col-sm-5">
                    <label style="padding-top: 8px;" for="download" class="col-sm-3 control-label">下载模版</label>
                    <div class="col-sm-8">
                        <a class="btn btn-sm btn-info" target="_blank"
                           href="{{ url("xqc/inventory/transfer-p-template?temp=TRANSFER_P") }}">
                            <i class="fa fa-download"></i>&nbsp;&nbsp;下载模版</a>
                    </div>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label"></label>
                <div class="col-sm-5">
                    <label style="padding-top: 8px;" for="reason" class="col-sm-3 control-label">申请站点</label>
                    <div class="col-sm-8">
                        <select id="iarea_id" name="iarea_id" required>
                            {{ getOptions(\App\Models\Basics\SysIArea::options()) }}
                        </select>
                    </div>
                </div>
            </div>
            <input type="hidden" id="deduct_transit" name="deduct_transit" value="1">
            <!-- <div class="form-group">
                <label class="col-sm-3 control-label"></label>
                <div class="col-sm-5">
                    <label style="padding-top: 8px;" for="reason" class="col-sm-3 control-label">扣减在途</label>
                    <div class="col-sm-8">
                        <input type="checkbox" class="grid-row-checkbox" id="deduct_transit" name="deduct_transit" value="1" checked>
                        <span class="help-block"><i class="fa fa-info-circle"></i>&nbsp;取消将不会扣减申请站点的在途库存，请谨慎操作</span>
                    </div>
                </div>
            </div> -->
            <div class="form-group">
                <label class="col-sm-3 control-label"></label>
                <div class="col-sm-5">
                    <label style="padding-top: 8px;" class="col-sm-3 control-label">文件</label>
                    <div class="col-sm-8">
                        <input type="file" style="margin-top: 4px;" name="source_file" accept=".xlsx,.xls" required>
                        <span class="help-block"><i class="fa fa-info-circle"></i>&nbsp;文件后缀为.xlsx或.xls</span>
                    </div>
                </div>
            </div>
            @include('layouts.upload.help')
        </div>
        <div class="box-footer">
            <div class="col-md-3"></div>
            <div class="col-md-5" style="text-align: center;">
                <div class="btn-group">
                    {{ csrf_field() }}
                    <button type="submit" class="btn btn-info">提交</button>
                </div>
            </div>
        </div>
    </form>
</div>
<script language="JavaScript" type="text/javascript">
    $(function () {
        $('#iarea_id').select2({placeholder: '申请站点', allowClear: true, width: '120px'});
        // $('.grid-row-checkbox').iCheck({checkboxClass:'icheckbox_minimal-blue'});
        // $("#deduct_transit").on('ifChanged', function(event) {
        //     if (this.checked) {
        //         $("#deduct_transit").val(1);
        //     } else {
        //         $("#deduct_transit").val(0);
        //     }
        // });
    });
</script>
